package com.turing.post.salesmanage.util;

import java.math.BigInteger;
import java.util.Date;
import java.util.List;

import javax.ejb.Local;
import javax.ejb.Remote;

import com.turing.post.util.PCPSApplicationException;

/**
 * 充值单付款信息
 * 
 * @author zxp
 * @Jan 17, 2013
 */
@Remote
@Local
public interface DepositOrderPaidDetailDao {
	/**
	 * 根据充值单付款信息主键编号查询充值单付款信息
	 * 
	 * @param depositOrderPaidId
	 *            充值单付款信息
	 * @return 充值单付款信息
	 */
	public DepositOrderPaidDetail getDepositOrderPaidDetailByPaidId(
			BigInteger depositOrderPaidId);

	/**
	 * 修改锁定记录
	 * 
	 * @param depositOrderPaidId
	 * @return
	 */
	public DepositOrderPaidDetail getDepositOrderPaidDetailForUpdate(
			BigInteger depositOrderPaidId);

	/**
	 * 根据充值单编号查询其所有付款明细
	 * 
	 * @param saleOrderId
	 * @return
	 */
	public List<DepositOrderPaidDetail> getDepositOrderPaidDetailListByDepositOrderId(
			BigInteger depositOrderId);

	/**
	 * 分页查询充值单付款
	 * 
	 * @param depositOrderId
	 *            充值单编号
	 * @param paidType
	 *            支付类型
	 * @param startTranTime
	 *            起始支付时间
	 * @param endTranTime
	 *            终止支付时间
	 * @param startPaidAmount
	 *            起始支付金额
	 * @param endPaidAmount
	 *            终止支付金额
	 * @param page
	 *            页码
	 * @return 充值单付款信息列表
	 */
	public List<DepositOrderPaidDetail> getDepositOrderPaidDetailListByCondition(
			BigInteger depositOrderId, String paidType,
			BigInteger startPaidAmount, BigInteger endPaidAmount,
			String paidClass, Integer page);

	/**
	 * 充值单付款查询记录数
	 * 
	 * @param depositOrderId
	 *            充值单编号
	 * @param paidType
	 *            支付类型
	 * @param startTranTime
	 *            起始支付时间
	 * @param endTranTime
	 *            终止支付时间
	 * @param startPaidAmount
	 *            起始支付金额
	 * @param endPaidAmount
	 *            终止支付金额
	 * @return 记录数
	 */
	public BigInteger getDepositOrderPaidDetailTotalByCondition(
			BigInteger depositOrderId, String paidType,
			BigInteger startPaidAmount, BigInteger endPaidAmount,
			String paidClass);

	/**
	 * 新增
	 * 
	 * @param dopd
	 * @throws PCPSApplicationException
	 */
	public void insertDepositOrderPaidDetail(DepositOrderPaidDetail dopd)
			throws PCPSApplicationException;

	/**
	 * 修改
	 * 
	 * @param dopd
	 * @throws PCPSApplicationException
	 */
	public void updateDepositOrderPaidDetail(DepositOrderPaidDetail dopd)
			throws PCPSApplicationException;

	/**
	 * 产生指定机构某日充值汇总数据
	 * 
	 * @param saleBranchNo
	 * @param tranDate
	 * @return
	 */
	public List<BranchDaySett_Obj> getBranchDaySettByBranchNoAndTranDate(
			String saleBranchNo, Date tranDate);
}
